<!-- HTML header for doxygen 1.8.18-->
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "https://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
<meta http-equiv="X-UA-Compatible" content="IE=9"/>
<meta name="generator" content="Doxygen 1.9.1"/>
<meta name="viewport" content="width=device-width, initial-scale=1"/>
<title>Cube for iOS: CEngine类 参考</title>
<link href="tabs.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="jquery.js"></script>
<script type="text/javascript" src="dynsections.js"></script>
<link href="navtree.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="resize.js"></script>
<script type="text/javascript" src="navtreedata.js"></script>
<script type="text/javascript" src="navtree.js"></script>
<link href="search/search.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="search/searchdata.js"></script>
<script type="text/javascript" src="search/search.js"></script>
<link href="doxygen.css" rel="stylesheet" type="text/css" />
</head>
<body>
<div id="top"><!-- do not remove this div, it is closed by doxygen! -->
<div id="titlearea">
<table cellspacing="0" cellpadding="0">
 <tbody>
 <tr style="height: 56px;">
  <td id="projectalign" style="padding-left: 0.5em;">
   <div id="projectname">Cube for iOS
   </div>
  </td>
 </tr>
 </tbody>
</table>
</div>
<!-- end header part -->
<!-- 制作者 Doxygen 1.9.1 -->
<script type="text/javascript">
/* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&amp;dn=gpl-2.0.txt GPL-v2 */
var searchBox = new SearchBox("searchBox", "search",false,'搜索','.html');
/* @license-end */
</script>
<script type="text/javascript" src="menudata.js"></script>
<script type="text/javascript" src="menu.js"></script>
<script type="text/javascript">
/* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&amp;dn=gpl-2.0.txt GPL-v2 */
$(function() {
  initMenu('',true,false,'search.php','搜索');
  $(document).ready(function() { init_search(); });
});
/* @license-end */</script>
<div id="main-nav"></div>
</div><!-- top -->
<div id="side-nav" class="ui-resizable side-nav-resizable">
  <div id="nav-tree">
    <div id="nav-tree-contents">
      <div id="nav-sync" class="sync"></div>
    </div>
  </div>
  <div id="splitbar" style="-moz-user-select:none;" 
       class="ui-resizable-handle">
  </div>
</div>
<script type="text/javascript">
/* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&amp;dn=gpl-2.0.txt GPL-v2 */
$(document).ready(function(){initNavTree('interface_c_engine.html',''); initResizable(); });
/* @license-end */
</script>
<div id="doc-content">
<!-- window showing the filter options -->
<div id="MSearchSelectWindow"
     onmouseover="return searchBox.OnSearchSelectShow()"
     onmouseout="return searchBox.OnSearchSelectHide()"
     onkeydown="return searchBox.OnSearchSelectKey(event)">
</div>

<!-- iframe showing the search results (closed by default) -->
<div id="MSearchResultsWindow">
<iframe src="javascript:void(0)" frameborder="0" 
        name="MSearchResults" id="MSearchResults">
</iframe>
</div>

<div class="header">
  <div class="summary">
<a href="#pub-methods">构造函数</a> &#124;
<a href="#pub-static-methods">类方法</a> &#124;
<a href="#properties">属性</a> &#124;
<a href="interface_c_engine-members.html">所有成员列表</a>  </div>
  <div class="headertitle">
<div class="title">CEngine类 参考</div>  </div>
</div><!--header-->
<div class="contents">

<p>魔方引擎的入口类。 该类设计为单例，在应用程序中通过该类调用魔方的各个功能模块。  
 <a href="interface_c_engine.html#details">更多...</a></p>

<p><code>#import &lt;<a class="el" href="_c_engine_8h_source.html">CEngine.h</a>&gt;</code></p>
<div class="dynheader">
类 CEngine 继承关系图:</div>
<div class="dyncontent">
 <div class="center">
  <img src="interface_c_engine.png" alt=""/>
 </div></div>
<table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="pub-methods"></a>
构造函数</h2></td></tr>
<tr class="memitem:aef36ba48c9c95fb5991978bc687f4463"><td class="memItemLeft" align="right" valign="top">(void)&#160;</td><td class="memItemRight" valign="bottom">- <a class="el" href="interface_c_engine.html#aef36ba48c9c95fb5991978bc687f4463">startWithConfig:success:failure:</a></td></tr>
<tr class="memdesc:aef36ba48c9c95fb5991978bc687f4463"><td class="mdescLeft">&#160;</td><td class="mdescRight">启动魔方引擎。  <a href="interface_c_engine.html#aef36ba48c9c95fb5991978bc687f4463">更多...</a><br /></td></tr>
<tr class="separator:aef36ba48c9c95fb5991978bc687f4463"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a1dcd094b4fda19626e8e608deea695d2"><td class="memItemLeft" align="right" valign="top">(BOOL)&#160;</td><td class="memItemRight" valign="bottom">- <a class="el" href="interface_c_engine.html#a1dcd094b4fda19626e8e608deea695d2">startWithConfig:timeoutInMilliseconds:</a></td></tr>
<tr class="memdesc:a1dcd094b4fda19626e8e608deea695d2"><td class="mdescLeft">&#160;</td><td class="mdescRight">启动魔方引擎，该方法会阻塞当前线程，直到引擎启动成功或者失败。  <a href="interface_c_engine.html#a1dcd094b4fda19626e8e608deea695d2">更多...</a><br /></td></tr>
<tr class="separator:a1dcd094b4fda19626e8e608deea695d2"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a9fb67dc4031718b249e1718d4e68aaf4"><td class="memItemLeft" align="right" valign="top">(void)&#160;</td><td class="memItemRight" valign="bottom">- <a class="el" href="interface_c_engine.html#a9fb67dc4031718b249e1718d4e68aaf4">stop</a></td></tr>
<tr class="memdesc:a9fb67dc4031718b249e1718d4e68aaf4"><td class="mdescLeft">&#160;</td><td class="mdescRight">停止魔方引擎。  <a href="interface_c_engine.html#a9fb67dc4031718b249e1718d4e68aaf4">更多...</a><br /></td></tr>
<tr class="separator:a9fb67dc4031718b249e1718d4e68aaf4"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a255518be269134cb63083d27e971562b"><td class="memItemLeft" align="right" valign="top">(void)&#160;</td><td class="memItemRight" valign="bottom">- <a class="el" href="interface_c_engine.html#a255518be269134cb63083d27e971562b">suspend</a></td></tr>
<tr class="memdesc:a255518be269134cb63083d27e971562b"><td class="mdescLeft">&#160;</td><td class="mdescRight">挂起魔方引擎。用于应用程序退到后台。  <a href="interface_c_engine.html#a255518be269134cb63083d27e971562b">更多...</a><br /></td></tr>
<tr class="separator:a255518be269134cb63083d27e971562b"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:adf4a472c500998a70441cd09ce13f129"><td class="memItemLeft" align="right" valign="top">(void)&#160;</td><td class="memItemRight" valign="bottom">- <a class="el" href="interface_c_engine.html#adf4a472c500998a70441cd09ce13f129">resume</a></td></tr>
<tr class="memdesc:adf4a472c500998a70441cd09ce13f129"><td class="mdescLeft">&#160;</td><td class="mdescRight">恢复魔方引擎。用于应用程序回到前台。  <a href="interface_c_engine.html#adf4a472c500998a70441cd09ce13f129">更多...</a><br /></td></tr>
<tr class="separator:adf4a472c500998a70441cd09ce13f129"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ae32ae28394dfba11580c9451ad0aeaf6"><td class="memItemLeft" align="right" valign="top">(BOOL)&#160;</td><td class="memItemRight" valign="bottom">- <a class="el" href="interface_c_engine.html#ae32ae28394dfba11580c9451ad0aeaf6">hasStarted</a></td></tr>
<tr class="memdesc:ae32ae28394dfba11580c9451ad0aeaf6"><td class="mdescLeft">&#160;</td><td class="mdescRight">是否已启动。  <a href="interface_c_engine.html#ae32ae28394dfba11580c9451ad0aeaf6">更多...</a><br /></td></tr>
<tr class="separator:ae32ae28394dfba11580c9451ad0aeaf6"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a8f7e07f8bfb457062f8e6fd20fc6b7ba"><td class="memItemLeft" align="right" valign="top">(BOOL)&#160;</td><td class="memItemRight" valign="bottom">- <a class="el" href="interface_c_engine.html#a8f7e07f8bfb457062f8e6fd20fc6b7ba">isReadyForPipeline</a></td></tr>
<tr class="memdesc:a8f7e07f8bfb457062f8e6fd20fc6b7ba"><td class="mdescLeft">&#160;</td><td class="mdescRight">数据通道是否就绪。  <a href="interface_c_engine.html#a8f7e07f8bfb457062f8e6fd20fc6b7ba">更多...</a><br /></td></tr>
<tr class="separator:a8f7e07f8bfb457062f8e6fd20fc6b7ba"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a36398dc294b7d9d7ccd62de9a3fb0388"><td class="memItemLeft" align="right" valign="top">(<a class="el" href="interface_c_self.html">CSelf</a> *_Nullable)&#160;</td><td class="memItemRight" valign="bottom">- <a class="el" href="interface_c_engine.html#a36398dc294b7d9d7ccd62de9a3fb0388">signInWithId:</a></td></tr>
<tr class="memdesc:a36398dc294b7d9d7ccd62de9a3fb0388"><td class="mdescLeft">&#160;</td><td class="mdescRight">签入指定 ID 的联系人。  <a href="interface_c_engine.html#a36398dc294b7d9d7ccd62de9a3fb0388">更多...</a><br /></td></tr>
<tr class="separator:a36398dc294b7d9d7ccd62de9a3fb0388"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a9935f27d01078427048be13e40261f35"><td class="memItemLeft" align="right" valign="top">(<a class="el" href="interface_c_self.html">CSelf</a> *_Nullable)&#160;</td><td class="memItemRight" valign="bottom">- <a class="el" href="interface_c_engine.html#a9935f27d01078427048be13e40261f35">signInWithId:andName:andContext:</a></td></tr>
<tr class="memdesc:a9935f27d01078427048be13e40261f35"><td class="mdescLeft">&#160;</td><td class="mdescRight">签入指定的联系人。  <a href="interface_c_engine.html#a9935f27d01078427048be13e40261f35">更多...</a><br /></td></tr>
<tr class="separator:a9935f27d01078427048be13e40261f35"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a7fe434d8ef7e4b684ae09fb62896ccec"><td class="memItemLeft" align="right" valign="top">(<a class="el" href="interface_c_contact_service.html">CContactService</a> *_Nullable)&#160;</td><td class="memItemRight" valign="bottom">- <a class="el" href="interface_c_engine.html#a7fe434d8ef7e4b684ae09fb62896ccec">getContactService</a></td></tr>
<tr class="memdesc:a7fe434d8ef7e4b684ae09fb62896ccec"><td class="mdescLeft">&#160;</td><td class="mdescRight">获取联系人服务模块。  <a href="interface_c_engine.html#a7fe434d8ef7e4b684ae09fb62896ccec">更多...</a><br /></td></tr>
<tr class="separator:a7fe434d8ef7e4b684ae09fb62896ccec"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a8a9451e3d9b69d5cb119c91188c8e744"><td class="memItemLeft" align="right" valign="top">(<a class="el" href="interface_c_messaging_service.html">CMessagingService</a> *_Nullable)&#160;</td><td class="memItemRight" valign="bottom">- <a class="el" href="interface_c_engine.html#a8a9451e3d9b69d5cb119c91188c8e744">getMessagingService</a></td></tr>
<tr class="memdesc:a8a9451e3d9b69d5cb119c91188c8e744"><td class="mdescLeft">&#160;</td><td class="mdescRight">获取消息服务模块。  <a href="interface_c_engine.html#a8a9451e3d9b69d5cb119c91188c8e744">更多...</a><br /></td></tr>
<tr class="separator:a8a9451e3d9b69d5cb119c91188c8e744"><td class="memSeparator" colspan="2">&#160;</td></tr>
</table><table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="pub-static-methods"></a>
类方法</h2></td></tr>
<tr class="memitem:a771fcc7d7fd4fc45a08df7a386c9f5ab"><td class="memItemLeft" align="right" valign="top">(<a class="el" href="interface_c_engine.html">CEngine</a> *_Nonnull)&#160;</td><td class="memItemRight" valign="bottom">+ <a class="el" href="interface_c_engine.html#a771fcc7d7fd4fc45a08df7a386c9f5ab">sharedInstance</a></td></tr>
<tr class="memdesc:a771fcc7d7fd4fc45a08df7a386c9f5ab"><td class="mdescLeft">&#160;</td><td class="mdescRight">获取引擎单例。  <a href="interface_c_engine.html#a771fcc7d7fd4fc45a08df7a386c9f5ab">更多...</a><br /></td></tr>
<tr class="separator:a771fcc7d7fd4fc45a08df7a386c9f5ab"><td class="memSeparator" colspan="2">&#160;</td></tr>
</table><table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="properties"></a>
属性</h2></td></tr>
<tr class="memitem:a952aaf21ef664953fa6bf8401efe0aa2"><td class="memItemLeft" align="right" valign="top">NSString *_Nonnull&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="interface_c_engine.html#a952aaf21ef664953fa6bf8401efe0aa2">version</a></td></tr>
<tr class="memdesc:a952aaf21ef664953fa6bf8401efe0aa2"><td class="mdescLeft">&#160;</td><td class="mdescRight">内核实例。  <a href="interface_c_engine.html#a952aaf21ef664953fa6bf8401efe0aa2">更多...</a><br /></td></tr>
<tr class="separator:a952aaf21ef664953fa6bf8401efe0aa2"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a9038b996f31c0fcb765ee3afae594a31"><td class="memItemLeft" align="right" valign="top"><a class="el" href="interface_c_kernel.html">CKernel</a> *_Nonnull&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="interface_c_engine.html#a9038b996f31c0fcb765ee3afae594a31">kernel</a></td></tr>
<tr class="memdesc:a9038b996f31c0fcb765ee3afae594a31"><td class="mdescLeft">&#160;</td><td class="mdescRight">内核实例。  <a href="interface_c_engine.html#a9038b996f31c0fcb765ee3afae594a31">更多...</a><br /></td></tr>
<tr class="separator:a9038b996f31c0fcb765ee3afae594a31"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ab23ede12a921d05ad412d3041f6f8611"><td class="memItemLeft" align="right" valign="top"><a class="el" href="interface_c_error.html">CError</a> *_Nonnull&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="interface_c_engine.html#ab23ede12a921d05ad412d3041f6f8611">lastError</a></td></tr>
<tr class="memdesc:ab23ede12a921d05ad412d3041f6f8611"><td class="mdescLeft">&#160;</td><td class="mdescRight">最近一次发生的错误。  <a href="interface_c_engine.html#ab23ede12a921d05ad412d3041f6f8611">更多...</a><br /></td></tr>
<tr class="separator:ab23ede12a921d05ad412d3041f6f8611"><td class="memSeparator" colspan="2">&#160;</td></tr>
</table>
<a name="details" id="details"></a><h2 class="groupheader">详细描述</h2>
<div class="textblock"><p>魔方引擎的入口类。 该类设计为单例，在应用程序中通过该类调用魔方的各个功能模块。 </p>
</div><h2 class="groupheader">函数文档</h2>
<a id="a7fe434d8ef7e4b684ae09fb62896ccec"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a7fe434d8ef7e4b684ae09fb62896ccec">&#9670;&nbsp;</a></span>getContactService</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">- (<a class="el" href="interface_c_contact_service.html">CContactService</a> * _Nullable) getContactService </td>
          <td></td>
          <td class="paramname"></td>
          <td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>获取联系人服务模块。 </p>
<dl class="section return"><dt>返回</dt><dd>返回联系人服务模块实例。 </dd></dl>

</div>
</div>
<a id="a8a9451e3d9b69d5cb119c91188c8e744"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a8a9451e3d9b69d5cb119c91188c8e744">&#9670;&nbsp;</a></span>getMessagingService</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">- (<a class="el" href="interface_c_messaging_service.html">CMessagingService</a> * _Nullable) getMessagingService </td>
          <td></td>
          <td class="paramname"></td>
          <td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>获取消息服务模块。 </p>
<dl class="section return"><dt>返回</dt><dd>返回消息服务模块实例。 </dd></dl>

</div>
</div>
<a id="ae32ae28394dfba11580c9451ad0aeaf6"></a>
<h2 class="memtitle"><span class="permalink"><a href="#ae32ae28394dfba11580c9451ad0aeaf6">&#9670;&nbsp;</a></span>hasStarted</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">- (BOOL) hasStarted </td>
          <td></td>
          <td class="paramname"></td>
          <td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>是否已启动。 </p>
<dl class="section return"><dt>返回</dt><dd>引擎已启动返回 <code>TRUE</code> ，否则返回 <code>FALSE</code> 。 </dd></dl>

</div>
</div>
<a id="a8f7e07f8bfb457062f8e6fd20fc6b7ba"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a8f7e07f8bfb457062f8e6fd20fc6b7ba">&#9670;&nbsp;</a></span>isReadyForPipeline</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">- (BOOL) isReadyForPipeline </td>
          <td></td>
          <td class="paramname"></td>
          <td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>数据通道是否就绪。 </p>
<dl class="section return"><dt>返回</dt><dd>如果数据通道已经连接到服务器返回 <code>TRUE</code> 。 </dd></dl>

</div>
</div>
<a id="adf4a472c500998a70441cd09ce13f129"></a>
<h2 class="memtitle"><span class="permalink"><a href="#adf4a472c500998a70441cd09ce13f129">&#9670;&nbsp;</a></span>resume</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">- (void) resume </td>
          <td></td>
          <td class="paramname"></td>
          <td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>恢复魔方引擎。用于应用程序回到前台。 </p>

</div>
</div>
<a id="a771fcc7d7fd4fc45a08df7a386c9f5ab"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a771fcc7d7fd4fc45a08df7a386c9f5ab">&#9670;&nbsp;</a></span>sharedInstance</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">+ (<a class="el" href="interface_c_engine.html">CEngine</a> * _Nonnull) sharedInstance </td>
          <td></td>
          <td class="paramname"></td>
          <td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>获取引擎单例。 </p>
<dl class="section return"><dt>返回</dt><dd>返回魔方引擎的实例。 </dd></dl>

</div>
</div>
<a id="a36398dc294b7d9d7ccd62de9a3fb0388"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a36398dc294b7d9d7ccd62de9a3fb0388">&#9670;&nbsp;</a></span>signInWithId:</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">- (<a class="el" href="interface_c_self.html">CSelf</a> * _Nullable) signInWithId: </td>
          <td></td>
          <td class="paramtype">(UInt64)&#160;</td>
          <td class="paramname"><em>contactId</em></td>
          <td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>签入指定 ID 的联系人。 </p>
<dl class="params"><dt>参数</dt><dd>
  <table class="params">
    <tr><td class="paramname">contactId</td><td>指定联系人 ID 。 </td></tr>
  </table>
  </dd>
</dl>
<dl class="section return"><dt>返回</dt><dd>返回当前签入的 <code><a class="el" href="interface_c_self.html" title="用户描述自己的账号。">CSelf</a></code> 实例。 </dd></dl>

</div>
</div>
<a id="a9935f27d01078427048be13e40261f35"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a9935f27d01078427048be13e40261f35">&#9670;&nbsp;</a></span>signInWithId:andName:andContext:</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">- (<a class="el" href="interface_c_self.html">CSelf</a> * _Nullable) <a class="el" href="interface_c_engine.html#a36398dc294b7d9d7ccd62de9a3fb0388">signInWithId:</a> </td>
          <td></td>
          <td class="paramtype">(UInt64)&#160;</td>
          <td class="paramname"><em>contactId</em></td>
        </tr>
        <tr>
          <td class="paramkey">andName:</td>
          <td></td>
          <td class="paramtype">(NSString *_Nonnull)&#160;</td>
          <td class="paramname"><em>name</em></td>
        </tr>
        <tr>
          <td class="paramkey">andContext:</td>
          <td></td>
          <td class="paramtype">(NSDictionary *_Nullable)&#160;</td>
          <td class="paramname"><em>context</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td></td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>签入指定的联系人。 </p>
<dl class="params"><dt>参数</dt><dd>
  <table class="params">
    <tr><td class="paramname">contactId</td><td>指定联系人 ID 。 </td></tr>
    <tr><td class="paramname">name</td><td>指定联系人名称。 </td></tr>
    <tr><td class="paramname">context</td><td>指定联系人的上下文数据。 </td></tr>
  </table>
  </dd>
</dl>
<dl class="section return"><dt>返回</dt><dd>返回当前签入的 <code><a class="el" href="interface_c_self.html" title="用户描述自己的账号。">CSelf</a></code> 实例。 </dd></dl>

</div>
</div>
<a id="aef36ba48c9c95fb5991978bc687f4463"></a>
<h2 class="memtitle"><span class="permalink"><a href="#aef36ba48c9c95fb5991978bc687f4463">&#9670;&nbsp;</a></span>startWithConfig:success:failure:</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">- (void) startWithConfig: </td>
          <td></td>
          <td class="paramtype">(<a class="el" href="interface_c_kernel_config.html">CKernelConfig</a> *_Nonnull)&#160;</td>
          <td class="paramname"><em>config</em></td>
        </tr>
        <tr>
          <td class="paramkey">success:</td>
          <td></td>
          <td class="paramtype">(void(^)(<a class="el" href="interface_c_engine.html">CEngine</a> *_Nullable engine))&#160;</td>
          <td class="paramname"><em>success</em></td>
        </tr>
        <tr>
          <td class="paramkey">failure:</td>
          <td></td>
          <td class="paramtype">(void(^)(<a class="el" href="interface_c_error.html">CError</a> *_Nonnull error))&#160;</td>
          <td class="paramname"><em>failure</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td></td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>启动魔方引擎。 </p>
<dl class="params"><dt>参数</dt><dd>
  <table class="params">
    <tr><td class="paramname">config</td><td>内核配置。 </td></tr>
    <tr><td class="paramname">success</td><td>启动成功回调函数。 </td></tr>
    <tr><td class="paramname">failure</td><td>启动故障回调函数。 </td></tr>
  </table>
  </dd>
</dl>

</div>
</div>
<a id="a1dcd094b4fda19626e8e608deea695d2"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a1dcd094b4fda19626e8e608deea695d2">&#9670;&nbsp;</a></span>startWithConfig:timeoutInMilliseconds:</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">- (BOOL) startWithConfig: </td>
          <td></td>
          <td class="paramtype">(<a class="el" href="interface_c_kernel_config.html">CKernelConfig</a> *_Nonnull)&#160;</td>
          <td class="paramname"><em>config</em></td>
        </tr>
        <tr>
          <td class="paramkey">timeoutInMilliseconds:</td>
          <td></td>
          <td class="paramtype">(UInt64)&#160;</td>
          <td class="paramname"><em>timeoutInMilliseconds</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td></td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>启动魔方引擎，该方法会阻塞当前线程，直到引擎启动成功或者失败。 </p>
<dl class="params"><dt>参数</dt><dd>
  <table class="params">
    <tr><td class="paramname">config</td><td>内核配置。 </td></tr>
    <tr><td class="paramname">timeoutInMilliseconds</td><td>以毫秒为单位的超时时间。 </td></tr>
  </table>
  </dd>
</dl>
<dl class="section return"><dt>返回</dt><dd>如果启动成功返回 <code>TRUE</code> ，否则返回 <code>FALSE</code> 。如果启动失败，可以通过 <a class="el" href="interface_c_engine.html#ab23ede12a921d05ad412d3041f6f8611" title="最近一次发生的错误。">CEngine::lastError</a> 查看错误信息。 </dd></dl>

</div>
</div>
<a id="a9fb67dc4031718b249e1718d4e68aaf4"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a9fb67dc4031718b249e1718d4e68aaf4">&#9670;&nbsp;</a></span>stop</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">- (void) stop </td>
          <td></td>
          <td class="paramname"></td>
          <td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>停止魔方引擎。 </p>

</div>
</div>
<a id="a255518be269134cb63083d27e971562b"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a255518be269134cb63083d27e971562b">&#9670;&nbsp;</a></span>suspend</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">- (void) suspend </td>
          <td></td>
          <td class="paramname"></td>
          <td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>挂起魔方引擎。用于应用程序退到后台。 </p>

</div>
</div>
<h2 class="groupheader">属性说明</h2>
<a id="a9038b996f31c0fcb765ee3afae594a31"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a9038b996f31c0fcb765ee3afae594a31">&#9670;&nbsp;</a></span>kernel</h2>

<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">- (<a class="el" href="interface_c_kernel.html">CKernel</a>* _Nonnull) kernel</td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">read</span><span class="mlabel">nonatomic</span><span class="mlabel">strong</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">

<p>内核实例。 </p>

</div>
</div>
<a id="ab23ede12a921d05ad412d3041f6f8611"></a>
<h2 class="memtitle"><span class="permalink"><a href="#ab23ede12a921d05ad412d3041f6f8611">&#9670;&nbsp;</a></span>lastError</h2>

<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">- (<a class="el" href="interface_c_error.html">CError</a>* _Nonnull) lastError</td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">read</span><span class="mlabel">nonatomic</span><span class="mlabel">strong</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">

<p>最近一次发生的错误。 </p>

</div>
</div>
<a id="a952aaf21ef664953fa6bf8401efe0aa2"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a952aaf21ef664953fa6bf8401efe0aa2">&#9670;&nbsp;</a></span>version</h2>

<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">- (NSString* _Nonnull) version</td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">read</span><span class="mlabel">nonatomic</span><span class="mlabel">strong</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">

<p>内核实例。 </p>

</div>
</div>
<hr/>该类的文档由以下文件生成:<ul>
<li><a class="el" href="_c_engine_8h_source.html">CEngine.h</a></li>
</ul>
</div><!-- contents -->
</div><!-- doc-content -->
<!-- HTML footer for doxygen 1.8.18-->
<!-- start footer part -->
<div id="nav-path" class="navpath"><!-- id is needed for treeview function! -->
  <ul>
    <li class="navelem"><a class="el" href="interface_c_engine.html">CEngine</a></li>
    <li class="footer">制作者
    <a href="http://www.doxygen.org/index.html">
    <img class="footer" src="doxygen.png" alt="doxygen"/></a> 1.9.1 </li>
  </ul>
</div>
</body>
</html>
